package byx.container.annotation.demo.DefaultInjectDemo.e;

import byx.container.annotation.PackageContainer;
import byx.container.core.Container;
import org.junit.jupiter.api.Test;

import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertTrue;

public class Demo {
    @Test
    public void test() {
        Container container = new PackageContainer();

        Handler handler = container.getObject(Handler.class);
        assertTrue(handler instanceof MyHandler);
        assertEquals("my: hello", handler.handle("hello"));
    }
}
